package task1;

import java.util.Arrays;
import java.util.Scanner;

/**
 * Created with IntelliJ IDEA.
 * Description:
 * User: 东莞呵呵
 * Date:2022-05-10
 * Time:16:40
 */
public class TestDemo3 {
    public static int[] fun(int[] nums,int n){
        int[] ret=new int[2];
        for (int i = 0; i < nums.length; i++) {
            for (int j = 0; j < nums.length; j++) {
                if(nums[i]+nums[j]==n&&i!=j){
                    ret[0]=i;
                    ret[1]=j;
                }
            }
        }
        return ret;
    }

    public static void main(String[] args) {
        int[] nums={2,7,11,15};
        Scanner scanner=new Scanner(System.in);
        int n=scanner.nextInt();
        int[] ret=fun(nums,n);
        System.out.println(Arrays.toString(ret));
    }
}
